package com.spa.infrastructure.service.gaode.result;

import lombok.Data;

import java.util.List;

/**
 * {\"status\":\"1\",\
 * "regeocode\":{
 *  \"addressComponent\":
 *      {\
 *          "city\":[],
 *          \"province\":\"北京市\",
 *          \"adcode\":\"110108\",
 *          \"district\":\"海淀区\",
 *          \"towncode\":\"110108015000\",
 *          \"streetNumber\":{
 *              \"number\":\"5号\",
 *              \"location\":\"116.310454,39.992734\",
 *              \"direction\":\"东北\",
 *              \"distance\":\"94.5489\",
 *              \"street\":\"颐和园路\"
 *           },
 *           \"country\":\"中国\",
 *           \"township\":\"燕园街道\",
 *           \"businessAreas\":[
 *              {\"location\":\"116.303364,39.976410\",\"name\":\"万泉河\",\"id\":\"110108\"},
 *              {\"location\":\"116.314222,39.982490\",\"name\":\"中关村\",\"id\":\"110108\"},
 *              {\"location\":\"116.294214,39.996850\",\"name\":\"西苑\",\"id\":\"110108\"}
 *           ],
 *           \"building\":{\"name\":\"北京大学\",\"type\":\"科教文化服务;学校;高等院校\"},
 *           \"neighborhood\":{\"name\":\"北京大学\",\"type\":\"科教文化服务;学校;高等院校\"},
 *           \"citycode\":\"010\"},
 *           \"formatted_address\":\"北京市海淀区燕园街道北京大学\"},
 *           \"info\":\"OK\",
 *           \"infocode\":\"10000\"}
 */
@Data
public class ReGeoResult {

    private Integer status;

    private String info;

    private Regeocode regeocode;

    @Data
    public static class Regeocode {
        private AddressComponent addressComponent;

        private String formatted_address;

    }

    @Data
    public static class AddressComponent {
        private String country;
        private String province;
        private String city;
        private String district;
    }
}
